home *** CD-ROM | disk | FTP | other *** search
/ FishMarket 1.0 / FishMarket v1.0.iso / fishies / 351-375 / disk_365 / view80 / src / filefinder.h < prev    next >
C/C++ Source or Header  |  1992-05-06  |  2KB  |  76 lines

  1. /***************************************************************************
  2.  
  3.                         F I L E - F I N D E R
  4.                        ^^^^^^^^^^^^^^^^^^^^^^^
  5.  
  6.                         by  Federico Giannici
  7.  
  8.  
  9.                ***********   Header file  ***********
  10.  
  11.  
  12.  
  13.                                V 1.5
  14.  
  15.  
  16. Routine generalizzata di richiesta del nome di un file.
  17.  
  18.  
  19. filefinder( data )
  20.     struct  ffdata *data;          Struttura dati da usare (vedi definizione)
  21.  
  22.  
  23. Necessita apertura librerie:
  24.     Intuition.library
  25.     Graphics.library
  26.  
  27.  
  28. ***************************************************************************/
  29.  
  30.  
  31. #ifndef  EXEC_TYPES_H
  32. #include    "exec/types.h"
  33. #endif
  34.  
  35. #ifndef INTUITION_INTUITION_H
  36. #include    "intuition/intuition.h"
  37. #endif
  38.  
  39.  
  40. #define FFOK        0        /*   Valori di ritorno di filefinder()   */
  41. #define FFCANCEL    1
  42. #define FFERROR     2
  43.  
  44. #define FFFILELEN   30        /*   Lunghezza nome del file   */
  45. #define FFPATHLEN   100        /*   Lunghezza del path   */
  46. #define FFSUFFIXLEN 7        /*   Lunghezza del suffisso   */
  47. #define FFMAXLINE   100        /*   Numero massimo di files   */
  48.  
  49.  
  50. struct  ffdataline
  51.     {
  52.     BYTE    name[ FFFILELEN+1 ];
  53.     LONG    size;
  54.     LONG    type;
  55.     };
  56.  
  57. struct  ffdata
  58.     {
  59.     UBYTE   *title;                                 /* Da inizializzare */
  60.     struct  Screen  *screen;                        /* Da inizializzare */
  61.     UBYTE   file[ FFFILELEN+1 ];                    /* Da inizializzare */
  62.     UBYTE   path[ FFPATHLEN+1 ];                    /* Da inizializzare */
  63.     UBYTE   suffix[ FFSUFFIXLEN+1 ];                /* Da inizializzare */
  64.     UBYTE   complete[ FFPATHLEN+1+FFFILELEN+1 ];    /* path+file+suffix */
  65.     BOOL    valid;             /* se TRUE i dati seguenti sono validi, e   */
  66.     USHORT  shown, showtop;    /* non c'e` bisogno di leggere la directory */
  67.     ULONG   diskfree;
  68.     struct  ffdataline  line[ FFMAXLINE ];
  69.     };
  70.  
  71.  
  72. /*****   Proto   *****/
  73.  
  74. LONG filefinder( struct ffdata * );
  75.  
  76.